import cv2 as cv

img = cv.imread('../test_datas/messi5.jpg')
if img is None:
    print("[ERROR] fail to read Image!!!")
    exit(0)
cv.imshow("pic", img)
cv.waitKey(0);

print( '图像形状[Width,Height,Channels(Depth)]:',
      img.shape )
print( '图像所有的像素总个数:',
      img.size, '. Weight*Height*Channels =',
      img.shape[0]*img.shape[1]*img.shape[2] )
print( '图像像素值的类型:',
      img.dtype )

cv.destroyAllWindows()